<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>Title</title>
</head>
<body>
{% for depart in departs %}
	<li>{{ depart.title }}</li>
{% endfor %}

<hr>
<table border="1">
    <thead>
        <tr>
            <th>ID</th>
            <th>NAME</th>
            <th>AGE</th>
            <th>ACCOUNT</th>
            <th>GENDER</th>
            <th>DEPART</th>
            <th>CREAT_DATE</th>
            <th>ACTION</th>
        </tr>
    </thead>
    <tbody>
        {% for user in users %}
        	<tr>
                <td>{{ user.id }}</td>
                <td>{{ user.name }}</td>
                <td>{{ user.age }}</td>
                <td>{{ user.account }}</td>
                <td>{{ user.get_gender_display }}</td>
                <td>{{ user.depart.title}}</td>
                <td>{{ user.create_time|date:'Y-m-d H:m:s' }}</td>
                <td><a href="/d2/delete/?nid={{ user.id }}">DEL</a></td>
            </tr>
        {% endfor %}
    </tbody>
</table>
<hr>
<form method="post">
    {% csrf_token %}
    <input type="text" name="user" placeholder="名称">
    <input type="text" name="password" placeholder="密码">
    <input type="text" name="age" placeholder="年龄">
    性别：
    <input type="radio" name="gender" value="1">男
    <input type="radio" name="gender" value="2">女
    <input type="text" name="account" placeholder="账户金额">
    <input type="submit" value="提交">
</form>
</body>
</html>